package com.example.drug.jpa;

import java.util.List;

import com.example.common.entity.Img;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

public interface ImgRepository extends JpaRepository<Img, Long> {

    @Query(value = "select * from visit_img where patients_info_id_bigint = ?1 order by id_bigint desc",nativeQuery = true)
    List<Img> findAllBypatientsID(long patientsID);
}
